﻿<%@ Page Language="C#" MasterPageFile="~/Manager/MasterPage/PageTemplate.Master" AutoEventWireup="True"
    Codebehind="Default.aspx.cs" Inherits="BingZi.UIProduct.Default"
    Title="无标题页" %>

<asp:Content ID="Content1" ContentPlaceHolderID="PageBody" runat="server">
    <BingZiWebControls:HeadMenuWebControls ID="HeadMenuWebControls1" runat="server"
         HeadOPTxt="商品信息列表" HeadTitleTxt="商品信息">
        <BingZiWebControls:HeadMenuButtonItem ButtonPopedom="New" ButtonUrl="Manager.aspx?CMD=New"
            ButtonUrlType="Href" ButtonVisible="True" ButtonName="商品信息" />
    </BingZiWebControls:HeadMenuWebControls>
    <BingZiWebControls:TabOptionWebControls ID="TabOptionWebControls1" runat="server">
        <BingZiWebControls:TabOptionItem ID="TabOptionItem1" runat="server" Tab_Name="商品信息列表">
            <asp:GridView ID="GridView1" runat="server" OnSorting="GridView1_Sorting" 
                OnRowCreated="GridView1_RowCreated" onrowdatabound="GridView1_RowDataBound" >
                <Columns>
                    <asp:TemplateField SortExpression="ID" HeaderText="序号"> 
                        <ItemTemplate>
                        <a href="Manager.aspx?IDX=<%#Eval("ID")%>&CMD=List"><%# (this.AspNetPager1.CurrentPageIndex - 1) * this.AspNetPager1.PageSize + Container.DataItemIndex + 1%></a>
                        </ItemTemplate>
                        <ItemStyle Wrap="True" />  
                        <HeaderStyle Wrap="False" />    
                    </asp:TemplateField>
                      <asp:TemplateField SortExpression="Title" HeaderText="标题"> 
                        <ItemTemplate>
                        <a href="Manager.aspx?IDX=<%#Eval("ID")%>&CMD=List"><%#Eval("Title")%></a>
                        </ItemTemplate>
                        <ItemStyle Wrap="True" />  
                        <HeaderStyle Wrap="False" />    
                    </asp:TemplateField>
                    <asp:BoundField HeaderText="现价" SortExpression="PriceNow" DataField="PriceNow" />
                    <asp:BoundField HeaderText="原价" SortExpression="PriceOriginal" DataField="PriceOriginal" />
                    <asp:BoundField HeaderText="销量" SortExpression="SalesNumber" DataField="SalesNumber" />
                    <asp:BoundField HeaderText="开始时间" SortExpression="StartTime" DataField="StartTime" DataFormatString="{0:yyyy-MM-dd}" />
                    <asp:BoundField HeaderText="结束时间" SortExpression="EndTime" DataField="EndTime" DataFormatString="{0:yyyy-MM-dd}" />
                    <asp:BoundField HeaderText="置顶" SortExpression="IsTop" DataField="IsTop" />
                    <asp:BoundField HeaderText="状态" SortExpression="Status" DataField="Status" />
                  <%--  <asp:BoundField HeaderText="分类编号" SortExpression="CategoryID" DataField="CategoryID" />
                    <asp:BoundField HeaderText="区域" SortExpression="Area" DataField="Area" />
                    <asp:BoundField HeaderText="标题" SortExpression="Title" DataField="Title" />
                    <asp:BoundField HeaderText="副标题" SortExpression="Subtitle" DataField="Subtitle" />
                    <asp:BoundField HeaderText="现在价格" SortExpression="PriceNow" DataField="PriceNow" />
                    <asp:BoundField HeaderText="原价" SortExpression="PriceOriginal" DataField="PriceOriginal" />
                    <asp:BoundField HeaderText="最小成团数量" SortExpression="MinNumber" DataField="MinNumber" />
                    <asp:BoundField HeaderText="库存数量" SortExpression="InventoryNumber" DataField="InventoryNumber" />
                    <asp:BoundField HeaderText="销量" SortExpression="SalesNumber" DataField="SalesNumber" />
                    <asp:BoundField HeaderText="开始时间" SortExpression="StartTime" DataField="StartTime" />
                    <asp:BoundField HeaderText="结束时间" SortExpression="EndTime" DataField="EndTime" />
                    <asp:BoundField HeaderText="是否置顶" SortExpression="IsTop" DataField="IsTop" />
                    <asp:BoundField HeaderText="状态" SortExpression="Status" DataField="Status" />
                    <asp:BoundField HeaderText="最后更新时间" SortExpression="LastTime" DataField="LastTime" />
                    <asp:BoundField HeaderText="最后更新用户" SortExpression="LastUser" DataField="LastUser" />
                    <asp:BoundField HeaderText="最后更新IP" SortExpression="LastIP" DataField="LastIP" />--%>
                </Columns>
            </asp:GridView>
            <BingZiWebControls:AspNetPager ID="AspNetPager1" runat="server" OnPageChanged="AspNetPager1_PageChanged">
            </BingZiWebControls:AspNetPager>
            <asp:Button ID="Button2" Visible="false" CssClass="button_bak" runat="server" Text="删除" OnClientClick="return deleteop();" OnClick="Button2_Click" />
        </BingZiWebControls:TabOptionItem>
        <BingZiWebControls:TabOptionItem ID="TabOptionItem2" runat="server" Tab_Name="查询">
           <table width="100%" border="0" cellspacing="1" cellpadding="3" align="center">
              
                <tr>
                    <td class="table_body">
                        标题</td>
                    <td class="table_none">
                     
                        <asp:TextBox ID="Title_Input" title="请输入标题~512:" runat="server" CssClass="text_input"></asp:TextBox>
                    
                        </td>
                </tr>
                <tr>
                    <td class="table_body">
                        副标题</td>
                    <td class="table_none">
                     
                        <asp:TextBox ID="Subtitle_Input" title="请输入副标题~256:" runat="server" CssClass="text_input"></asp:TextBox>
                    
                        </td>
                </tr>
                <tr>
                    <td class="table_body">
                        商品详情</td>
                    <td class="table_none">
                     
                        <asp:TextBox ID="ContentText_Input" title="请输入商品详情~2147483647:" runat="server" CssClass="text_input"></asp:TextBox>
                    
                        </td>
                </tr>
               
                <tr>
                    <td colspan="4" align="right">
                        <asp:Button ID="Button1" runat="server" CssClass="button_bak" Text="查询" OnClick="Button1_Click" /></td>
                </tr>
            </table>
        </BingZiWebControls:TabOptionItem>
    </BingZiWebControls:TabOptionWebControls>

<script language="javascript" type="text/javascript">
<!--

function SelectAll()
{
   var e=document.getElementsByTagName("input");
   var IsTrue;
   if(document.getElementById("CheckboxAll").value=="0")
　 {
　　 IsTrue=true;
　　 document.getElementById("CheckboxAll").value="1"
　 }
　 else
　 {
　　IsTrue=false;
　　document.getElementById("CheckboxAll").value="0"
　　}
　　
　for(var i=0;i<e.length;i++)
　{
　　if (e[i].type=="checkbox")
　　{
　　   e[i].checked=IsTrue;
　　}
　}
}
function deleteop()
{
    var checkok = false;
    var e=document.getElementsByTagName("input");
    for(var i=0;i<e.length;i++)
　  {
　     if (e[i].type=="checkbox")
　　     {
　　         if (e[i].checked==true)
　　         {
　　             checkok = true;
　　             break;　　             
　　         }
　　     }  
　  }
　  if (checkok) 
        return confirm('删除后不可恢复,确认要批量删除选中记录吗？');
    else
    {
        
        alert("请选择要删除的记录!");
        return false;
    }
}
// -->
    </script>

</asp:Content>
